package ee.edisoft.action;

import java.util.ArrayList;
import java.util.List;

import com.opensymphony.xwork2.ActionSupport;

import ee.edisoft.common.model.HeaderModel;

public class HeadersAction extends ActionSupport{

	/**
	 * 
	 */
	private static final long serialVersionUID = -4670645225453172111L;
	private List<HeaderModel> headerList = new ArrayList<HeaderModel>();
	
	public List<HeaderModel> getHeaderList() {
		return headerList;
	}

	public String execute() {
		List <HeaderModel> items = HeaderModel.find("order by id desc");
		headerList.addAll(items);

		return SUCCESS;
	}
}
